package com.young.springdemo.service.visitorpattern;

import lombok.AllArgsConstructor;
import lombok.Data;

//正式员工的访问方式
@Data
@AllArgsConstructor
public class FulltimeEmployee implements Employee {

    private String name;//员工名称
    private double workHours;//工作时长
    private double weekWage;//员工周薪


    @Override
    public void accept(Department department) {
        department.visit(this);//调用访问者的访问方法
    }
}
